/*
2021-7-17 
https://www.acwing.com/problem/content/3773/
*/
#include<iostream>
#include<cstring>
#include<algorithm>

using namespace std;

int main()
{
    int T;
    cin>>T;
    
    string str;
    while(T--)
    {
        int cnt1=0,cnt2=0;
        int n,a,b,c;
        cin>>n>>a>>b>>c;
        cin>>str;
        for(auto s:str)
        {
            if(s=='0') cnt1++;
            else cnt2++;
        }
        cout<<cnt1*min(a,b+c)+cnt2*min(b,a+c)<<endl;
    }
    
    return 0;
}
